<div class="n_navi">
<a href="#">▲</a>&nbsp;|
<a href="#bottom">▼</a>
</div><!-- n_navi -->

<?php
Y('Module.load', 'booklog');
if ($this->Article['IsComment'] != 0) {
?>
<div class="n_comments">
<a name="comment">&nbsp;</a><br />
<b>この記事に投稿されたコメント</b><br />
<br />
<?php
	if ($ComList = Y('Module.List.booklog.getComments', $this->Article['ID'])) {
		foreach ($ComList as $Comment) {
?>
	<div class="n_comment">
<?php print nl2br(htmlspecialchars($Comment['Text'])); ?><br />
	<br />
	<div>
	<?php print date ('Y-m-d H:i:s', $Comment['RegistTime']); ?>&nbsp;|&nbsp;<?php print htmlspecialchars($Comment['Name']);?>
	</div>
	</div>
<?php
		}
	} else {
		print ('投稿されたコメントはありません。<br />'."\n");
	}

	if ($this->Article['IsComment'] == 2) {
?>

<br />
コメント投稿フォーム<a name="commentform">&nbsp;</a><br />

<form class="ajaxcomment" name="form" method="post" action="./booklog/comment/<?php print $this->Article['ID']; ?>">
<?php Y('Output.addHeader', '<script src="./vars/mod/booklog/js/ajaxcomment.js" type="text/javascript"></script>'); ?>
<input type="hidden" name="ArticleID" value="<?php print $this->Article['ID']; ?>" />
<dl class="h_form">
<dt><label for="Name">お名前：</label></dt>
<dd><input type="text" name="Name" size="40" value="<?php printY('Helper.list.session.Vars.booklog.LastCommentName'); ?>" id="Name" /></dd>
<dt><label for="URL">URL：</label></dt>
<dd><input type="text" name="URL" size="40" value="<?php printY('Helper.list.session.Vars.booklog.LastCommentURL'); ?>" id="URL" /></dd>
<dt><label for="Email">メール：</label></dt>
<dd><input type="text" name="Email" size="40" value="<?php printY('Helper.list.session.Vars.booklog.LastCommentEmail'); ?>" id="Email" /></dd>
<dt><label for="Text">コメント：</label></dt>
<dd><textarea name="Text" cols="40" rows="6" id="Text"></textarea></dd>
<dt><input type="submit" name="submit" value="投稿する" class="button" /></dt>
</dl>
</form>

<?php
	} else {
?>

<p>
現在コメントは受け付けていません。<br />
</p>
<?php
	}
?>

</div>

<?php
}
?>